home *** CD-ROM | disk | FTP | other *** search
/ Chip 2003 February / Chip_2003-02_cd1.bin / zkuste / xptools / install / Xsetup / setup.exe / {app} / plugins / XQ CMD Options 2.xpl < prev    next >
Text File  |  2002-11-24  |  1KB  |  64 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 6.0"
  2. "TYPE"="7"
  3. "COUNT"="3"
  4. "UIPATH"="System\Security\Disabled Features"
  5. "NAME"="Command Prompt CMD Enabled"
  6. "VERSION"="1.00"
  7. "OSVERSION"="000101"
  8. "LANGUAGE"="VBScript"
  9. "TEXT 1"="Allow Command Prompt and batch files (default)"
  10. "TEXT 2"="Disallow Command Prompt but allow batch files"
  11. "TEXT 3"="Disallow Command Prompt and disallow batch files"
  12. "DESCRIPTION 1"="This setting can be used to allow or disallow the command prompt and/or batch files (*.BAT, *.CMD)."
  13. "AUTHOR"="Xteq Systems"
  14. "CONTACTURL"="http://www.xteq.com"
  15. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  16. "COMMENT 1"=" "
  17.  
  18.  
  19.  
  20. sPath="HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\System\DisableCMD"
  21.  
  22.  
  23. Sub Plugin_Initialize 
  24.     i=RegReadValue(sPath)
  25.     if i=0 or IsEmpty(i) then
  26.        Call SetUIElement(1,true) 
  27.     else
  28.        if i=2 then
  29.           Call SetUIElement(2,true)
  30.        else
  31.           Call SetUIElement(3,true)
  32.        end if
  33.     end if  
  34. End Sub
  35.  
  36. Sub Plugin_CheckData(ElementIndex)
  37. End Sub
  38.  
  39. Sub Plugin_Apply(ElementIndex,ElementSubIndex)
  40.  i=0
  41.  
  42.  if GetUIElement(1)=true then i=0
  43.  if GetUIElement(2)=true then i=2
  44.  if GetUIElement(3)=true then i=1
  45.  
  46.  
  47.  
  48.  if i>0 then
  49.     Call RegWriteValue(sPath,i,2) 
  50.  else
  51.     s=RegReadValue(sPath)
  52.     if IsEmpty(s)=false then
  53.        Call RegDeleteValue(sPath)
  54.     end if
  55.  end if
  56. End Sub
  57.  
  58.  
  59. Sub Plugin_Terminate 
  60. End Sub
  61.  
  62.  
  63.  
  64.